package Tree;

import Main.Operators;
/**
 * Node class contains the 5 tuples of the node , the state of type object,
 * parentNode of type Node, depth of type int, operators of type Operators
 * and the pathCost of type int. It also contains the heuristic value of the
 * node of type int, and whether the node is a root node or not
 */
public class Node {
	
	boolean root;
	Node parentNode;
	int depth;
	int pathCost;
	Operators operator;
	Object state;
	int heuristic;

	public Node(boolean r, Node p, int d, Operators o, Object s) {
		root = r;
		parentNode = p;
		depth = d;
		operator = o;
		state = s;
	}

	public Node() {
	}

	public Object getState() {
		return state;
	}

	public void setState(Object state) {
		this.state = state;
	}

	public boolean isRoot() {
		return root;
	}

	public void setRoot(boolean root) {
		this.root = root;
	}

	public Node getParentNode() {
		return parentNode;
	}

	public void setParentNode(Node parentNode) {
		this.parentNode = parentNode;
	}

	public int getDepth() {
		return depth;
	}

	public void setDepth(int depth) {
		this.depth = depth;
	}

	public int getPathCost() {
		return pathCost;
	}

	public void setPathCost(int pathCost) {
		this.pathCost = pathCost;
	}

	public Operators getOperator() {
		return operator;
	}

	public void setOperator(Operators operator) {
		this.operator = operator;
	}

	public int getHeuristic() {
		return heuristic;
	}

	public void setHeuristic(int heuristic) {
		this.heuristic = heuristic;
	}
}